package com.cskaoyan.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.Map;

/**
 * @author stone
 * @date 2022/04/02 10:43
 */
@Data
@ConfigurationProperties(prefix = "db")
public class DataSourceProperties {
    String driver;
    String url;
    String username;
    String password;

    int age = 18;
    Boolean flag;

    //数组有两种写法
    String[] array1;
    String[] array2;

    List<String> list1;
    List<String> list2;

    //map有两种写法
    Map map1;
    Map map2;

    User user1;
    User user2;
}
